<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.ViewEventTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputText value="#{bundle.ViewEventLabel_eventID}"/>
                    <h:outputText value="#{eventController.selected.eventID}" title="#{bundle.ViewEventTitle_eventID}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_topic}"/>
                    <h:outputText value="#{eventController.selected.topic}" title="#{bundle.ViewEventTitle_topic}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_createDate}"/>
                    <h:outputText value="#{eventController.selected.createDate}" title="#{bundle.ViewEventTitle_createDate}">
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:outputText>
                    <h:outputText value="#{bundle.ViewEventLabel_startDate}"/>
                    <h:outputText value="#{eventController.selected.startDate}" title="#{bundle.ViewEventTitle_startDate}">
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:outputText>
                    <h:outputText value="#{bundle.ViewEventLabel_endDate}"/>
                    <h:outputText value="#{eventController.selected.endDate}" title="#{bundle.ViewEventTitle_endDate}">
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:outputText>
                    <h:outputText value="#{bundle.ViewEventLabel_located}"/>
                    <h:outputText value="#{eventController.selected.located}" title="#{bundle.ViewEventTitle_located}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_maxNoOfParticipants}"/>
                    <h:outputText value="#{eventController.selected.maxNoOfParticipants}" title="#{bundle.ViewEventTitle_maxNoOfParticipants}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_curNoOfParticipants}"/>
                    <h:outputText value="#{eventController.selected.curNoOfParticipants}" title="#{bundle.ViewEventTitle_curNoOfParticipants}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_fee}"/>
                    <h:outputText value="#{eventController.selected.fee}" title="#{bundle.ViewEventTitle_fee}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_imageurl}"/>
                    <h:outputText value="#{eventController.selected.imageurl}" title="#{bundle.ViewEventTitle_imageurl}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_details}"/>
                    <h:outputText value="#{eventController.selected.details}" title="#{bundle.ViewEventTitle_details}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_speakerID}"/>
                    <h:outputText value="#{eventController.selected.speakerID}" title="#{bundle.ViewEventTitle_speakerID}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_createPerID}"/>
                    <h:outputText value="#{eventController.selected.createPerID}" title="#{bundle.ViewEventTitle_createPerID}"/>
                    <h:outputText value="#{bundle.ViewEventLabel_categoryID}"/>
                    <h:outputText value="#{eventController.selected.categoryID}" title="#{bundle.ViewEventTitle_categoryID}"/>
                </h:panelGrid>
                <br />
                <h:commandLink action="#{eventController.destroyAndView}" value="#{bundle.ViewEventDestroyLink}"/>
                <br />
                <br />
                <h:commandLink action="Edit" value="#{bundle.ViewEventEditLink}"/>
                <br />
                <h:commandLink action="#{eventController.prepareCreate}" value="#{bundle.ViewEventCreateLink}" />
                <br />
                <h:commandLink action="#{eventController.prepareList}" value="#{bundle.ViewEventShowAllLink}"/>
                <br />
                <br />
                <h:commandLink value="#{bundle.ViewEventIndexLink}" action="/index" immediate="true" />

            </h:form>
        </ui:define>
    </ui:composition>

</html>
